package cn.wolfcode.luowowo.home.service;

import cn.wolfcode.luowowo.article.domain.Travel;
import cn.wolfcode.luowowo.article.query.MytravelQueryObject;
import cn.wolfcode.luowowo.comment.domain.ScenicComment;
import cn.wolfcode.luowowo.common.exception.LogicException;
import cn.wolfcode.luowowo.home.vo.UserHomeVO;
import cn.wolfcode.luowowo.member.domain.UserInfo;
import com.github.pagehelper.PageInfo;

import java.util.List;

/**
 * Created by Administrator on 2020/1/9.
 */
public interface IUserHomeService {
    /**
     * 查询我的空间首页
     * @param userInfo  登录的个人信息
     * @return  返回个人空间查询对象vo
     */
    UserHomeVO listMyHome(UserInfo userInfo);

    /**
     * 根据用户id查询游记集合
     * @param id
     * @return
     */
    List<Travel> listAllByUserId(Long id);

    PageInfo<Travel> queryAllTravelByUserId(MytravelQueryObject qo);

    /**
     * 获取验证码并发送  测试 返回验证码到前台
     * @param phone 手机号码
     */
    String sendVerity(String phone) throws LogicException;


    /**
     * 输入验证码和手机号码  验证
     * @param phone
     * @param verifyCode
     * @return
     */
    Boolean checkVerityCode(String phone, String verifyCode);

    /**
     * 根据传入的点评集合,给每个点评设置进回复数和点评数
     * @param scenic
     * @return
     */
    List<ScenicComment> setReplayAndThumb(List<ScenicComment> scenic);
}
